#include "Entity.h"

Entity::Entity(Mesh * mesh, GLuint glId)
{
	this->mesh = mesh;
	this->glId = glId;
}

Entity::~Entity()
{
	delete mesh;
}

Mesh * Entity::getMesh()
{
	return mesh;
}

void Entity::draw()
{
	glEnable(GL_TEXTURE_2D);
	glPushMatrix();
	glCallList(glId);
	glPopMatrix();
	glDisable(GL_TEXTURE_2D);
}